<div class="box">
	<div class="heading">
		<h1><img src="/assets/admin/book.png" alt="" />History</h1>
		<div class="buttons"></div>
	</div>
	<div class="content">
		<table class="list">
			<thead>
				<tr>
					<td width="1" style="text-align: center;">
					<input type="checkbox" class="checkall">
					</td>
					<td class="left">User ID</td>
					<td class="left">User Email</td>
					<td class="left">User Role</td>
					<td class="left">Date</td>
					<td class="left">Log</td>
					<td class="center">Action</td>
				</tr>
			</thead>
			<tbody>
				<%= form_tag search_manager_borrows_path, :method => :get do %>
				<tr class="search">
					<td></td>
					<td></td>
					<td></td>
					<td></td>
					<td></td>
					<td></td>
					<td align="center" style="width:130px;">
					 <% end %>
					<%= form_tag delete_multiple_manager_borrows_path, :method => :delete do %>
					<%= submit_tag "Delete", :confirm => "Are you sure ?", :id => "yt0" %> </td>
				</tr>
				<% @histories.each do |history| %>					
				<tr>
					<td style="text-align: center;"> <%= check_box_tag 'borrow_ids[]', history.id, false, :class => 'checkitem' %> </td>
					<td class="left"><%= history.userid %></td>
					<td class="left"><%= history.useremail %></td>
					<td class="left"><% if(history.userrole == 1) %>ADMIN
					<% else %>USER
					<% end %></td>					
					<td class="left"><%= history.created_at %></td>					
					<td class="left"><%= history.action %></td>
					<td class="center"><%= link_to 'Delete', manager_borrow_path(history), :method => :delete, :confirm => "Are you sure ?" %> </td>
				</tr>
				<% end %>
			</tbody>
		</table>
	</div>
</div>
<% end %>